﻿<!-- application/layouts/scripts/layoutprofile.phtml -->
<?php echo $this->doctype() ?>
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>LogisticWay</title>
        <?php $this->headLink()->prependStylesheet('/css/theme-1.css'); ?>
        <?php $this->headLink()->prependStylesheet('/css/jquery.fancybox-1.3.4.css'); ?>
        <?php $this->headLink()->prependStylesheet('/css/another_pages.css'); ?>
        <?php $this->headLink()->prependStylesheet('/css/maps.css'); ?>
        <?php $this->headScript()->prependFile('/js/superfish.js'); ?>
        <?php $this->headScript()->prependFile('/js/twitter.min.js'); ?>
        <?php $this->headScript()->prependFile('/js/jquery.fancybox-1.3.4.pack.js'); ?>
        <?php $this->headScript()->prependFile('/js/jquery.validate.min.js'); ?>
        <?php $this->headScript()->prependFile('/js/jquery.scrollTo-1.4.2-min.js'); ?>
        <?php $this->headScript()->prependFile('/js/styleswitcher.js'); ?>
        <?php $this->headScript()->prependFile('/js/localisation/changelang.js'); ?>
        <?php $this->headScript()->prependFile('http://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js'); ?>
        <?php $this->headScript()->prependFile('https://maps.google.com/maps/api/js?libraries=panoramio&sensor=true'); ?>
        <?php $this->headScript()->appendFile('http://code.jquery.com/jquery-1.7.2.min.js'); ?>
        <?php $this->headScript()->appendFile('/js/gmaps/jquery-ui-1.8.1.custom.min.js'); ?>
        <?php $this->headScript()->appendFile('/js/gmaps/autocomplete.js'); ?>
        <?php $this->headScript()->appendFile('/js/gmaps/save.js'); ?> 
        <?php echo $this->headLink(); ?>
        <?php echo $this->headScript(); ?>
    </head>
    <body id="home">
    <header>
        <div id="header-inner">
            <!-- The name of your website -->
            <?php echo "<a href=" . $this->url(array(
                                    'controller' => 'index',
                                    'action' => 'index'))
                                    ." class=\"logo\">".$this->translate('Home')."</a>"; ?>

            <!-- Main navigation -->
            <nav>
                <ul>
                    <li><?php echo "<a href=" . $this->url(array(
                                    'controller' => 'index',
                                    'action' => 'index'))
                                    .">".$this->translate('Home')."</a>"; ?></li>
                    <li><?php echo "<a href=" . $this->url(array(
                                    'controller' => 'profile',
                                    'action' => 'update',
                                    'id' => $this->data['id'])) . ">".$this->translate('Update profile')."</a>"; ?></li>
                    <li><?php echo "<a href=" . $this->url(array(
                                    'controller' => 'profile',
                                    'action' => 'addstatus',
                                    'id' => $this->data['id'])) . ">".$this->translate('Add payment')."</a>"; ?></li>
                    <li><?php echo "<a href=" . $this->url(array(
                                    'controller' => 'routes',
                                    'action' => 'savedroutes')) . ">".$this->translate('Saved routes')."</a>"?></li>
                </ul>
            </nav>
            <!-- Secondary navigation -->
            <ul id="sec-navi">
<?php 
require_once APPLICATION_PATH . '/configs/menu.php';
$role = Zend_Auth::getInstance()->hasIdentity()?Zend_Auth::getInstance()->getIdentity()->role:'guest';

foreach ($config[$role] as $key => $value) {?>
<li><a href="<?php echo $value; ?>"><?php echo $key; ?></a></li>
<?php } ?>

<div id="lang-navi">    
  <dl id="sample" class="dropdown">
        <dt>
          <a href="#">
          <?php
              $url =  $_SERVER['REQUEST_URI'];
              $lang = substr($url, 1, 2);              
              echo "<img class=\"flag\" src=\"/img/$lang.png\" />$lang" 
          ?>
          </a>
        </dt>
        <dd>
            <ul>
                <li><a href="#"><img class="flag" src="/img/ru.png" style="vertical-align: middle;" onclick="langChange('ru');" />ru</a></li>
                <li><a href="#"><img class="flag" src="/img/en.png" style="vertical-align: middle;" onclick="langChange('en');" />en</a></li>
                <li><a href="#"><img class="flag" src="/img/fr.png" style="vertical-align: middle;" onclick="langChange('fr');" />fr</a></li>
            </ul>
        </dd>
    </dl>  			
</div>
 </ul>
        </div><!-- /header-inner -->
    </header>
    <div id="slidermain">
         <?php echo $this->placeholder('slidermain'); ?>
    </div>
   
    <!--/wrapper -->
    <?php
                $container = new Zend_Navigation();
                $this->navigation($container);

                $container->addPage(
    //INDEX
    array(
        'label'      => $this->translate('Index'),
        'controller' => 'index',
        'action'     => 'index',
        'pages'      =>
        array(
           //MARKERS index
            array(
                'label'      => $this->translate('Markers'),
                'controller' => 'markers',
                'action'     => 'index',
                'pages'      =>
                array(
                    //MARKERS add
                    array(
                        'label'      => $this->translate('Add markers'),
                        'controller' => 'markers',
                        'action'     => 'addmarker'                        
                    ),
                    //MARKERS show all markers
                    array(
                        'label'      => $this->translate('All markers'),
                        'controller' => 'markers',
                        'action' => 'allmarkers'
                    ),
                    //MARKERS add category
                    array(
                        'label'      => $this->translate('Add category'),
                        'controller' => 'markers',
                        'action' => 'addcategory'
                    ),
                    //MARKERS all categories
                    array(
                        'label'      => $this->translate('All categories'),
                        'controller' => 'markers',
                        'action' => 'allcategories'
                    ),
                    //MARKERS update category
                    array(
                        'label'      => $this->translate('Update category'),
                        'controller' => 'markers',
                        'action' => 'updatecategory'
                    ),
                    //MARKERS on map
                    array(
                        'label'      => $this->translate('Markers on map'),
                        'controller' => 'markers',
                        'action' => 'xml'
                    )
                    
                )
            ),
            //ROUTES index
            array(
                'label'      => $this->translate('Routes'),
                'controller' => 'routes',
                'action'     => 'index',
                'pages'      =>
                array(
                    //ROUTES add
                    array(
                        'label'      => $this->translate('View the route'),
                        'controller' => 'routes',
                        'action' => 'viewmap'
                    ),
                    //ROUTES saved
                    array(
                        'label'      => $this->translate('Saved routes'),
                        'controller' => 'routes',
                        'action' => 'savedroutes'
                    ),
                    //ROUTES on map
                    array(
                        'label'      => $this->translate('Route on map'),
                        'controller' => 'routes',
                        'action' => 'routeonmap'
                    )
                )
            ),
            //GPS index
            array(
                'label'      => $this->translate('GPS'),
                'controller' => 'gps',
                'action'     => 'index',
                'pages'      =>
                array(
                    //GPS navigation
                    array(
                        'label'      => $this->translate('Navigation'),
                        'controller' => 'gps',
                        'action' => 'navigation'
                    ),
                    //GPS addimei
                    array(
                        'label'      => $this->translate('Add imei'),
                        'controller' => 'gps',
                        'action' => 'addimei'
                    ),
                    //GPS saved routes
                    array(
                        'label'      => $this->translate('Saved routes'),
                        'controller' => 'gps',
                        'action' => 'showfullroute'
                    ),
                    //GPS real time
                    array(
                        'label'      => $this->translate('In real time'),
                        'controller' => 'gps',
                        'action' => 'inrealtime'
                    ),
                )
            ),
            
            
              //RATES index
            array(
                'label'      => $this->translate('Rates'),
                'controller' => 'rates',
                'action'     => 'index',
                'pages'      =>
                array(
                    //RATES add
                    array(
                        'label'      => $this->translate('Add rate'),
                        'controller' => 'rates',
                        'action' => 'add'
                    ),
                    array(
                        'label'      => $this->translate('Update rate'),
                        'controller' => 'rates',
                        'action' => 'update'
                    )
                )
            ),
            //AUTHORIZATION
            array(
                'label'      => $this->translate('Authorization'),
                'controller' => 'auth',
                'action'     => 'login'
            ),
            //REGISTRATION
            array(
                'label'      => $this->translate('Registration'),
                'controller' => 'registration',
                'action'     => 'registration'
            ),
            //ADMIN index
            array(
                'label'      => $this->translate('Admin'),
                'controller' => 'admin',
                'action'     => 'index',
                'pages'      =>
                array(
                    //ADMIN show
                    array(
                        'label'      => $this->translate('Show'),
                        'controller' => 'admin',
                        'action' => 'show'
                    ),
                    //ADMIN update
                    array(
                        'label'      => $this->translate('Update'),
                        'controller' => 'admin',
                        'action' => 'update'
                    ),
                    //ADMIN adduser
                    array(
                        'label'      => $this->translate('Add'),
                        'controller' => 'admin',
                        'action' => 'add'
                    ),
                    //ADMIN add balance
                    array(
                        'label'      => $this->translate('Add balance'),
                        'controller' => 'admin',
                        'action' => 'addstatus'
                    ),
                    //Transactions
                    array(
                        'label'      => $this->translate('Transactions'),
                        'controller' => 'admin',
                        'action' => 'transactions'
                    ),
                    //Requisites
                    array(
                        'label'      => $this->translate('Requisites'),
                        'controller' => 'requisites',
                        'action' => 'updaterequisaction'
                    )
                )
            ),
            //PROFILE
            array(
                'label'      => $this->translate('Profile'),
                'controller' => 'profile',
                'action'     => 'index',
                'pages'      =>
                array(
                    //PROFILE update
                    array(
                        'label'      => $this->translate('Update'),
                        'controller' => 'profile',
                        'action' => 'update'
                    ),
                    //SAVED routes
                    array(
                        'label'      => $this->translate('Saved routes'),
                        'controller' => 'routes',
                        'action' => 'saveroutes'
                    ),
                    //PROFILE addbalance
                    array(
                        'label'      => $this->translate('Add status'),
                        'controller' => 'profile',
                        'action' => 'addstatus'
                    ),
                    //PROFILE selectrate
                    array(
                        'label'      => $this->translate('Select rate'),
                        'controller' => 'profile',
                        'action' => 'selectrate'
                    ),
                    //PROFILE pay
                    array(
                        'label'      => $this->translate('Pay'),
                        'controller' => 'profile',
                        'action' => 'pay'
                    ) 
                )
            )
        )
    )
); ?>
                <div id="pageHeader">
                    <div class="wrapper">
                        <p id="breadcrumbs">
                            <?php echo $this->navigation()->breadcrumbs()->setLinkLast(false)->setMinDepth(0)->render(); ?>
                        </p>
                    </div>

                </div>

                   
<?php echo $this->layout()->content ?>
   

    <footer>
        <div class="wrapper">
            <div class="one-third">
                <center><h3><?php echo $this->translate('About'); ?></h3></center>

                <p><?php echo $this->translate('We are an innovative and vastly developing company. We are engaged in web development and financial services'); ?>.</p>

                <ul>
                    <li><?php echo $this->translate('Rybal\'s\'ka St, 2, Kyiv, Ukraine, 01011'); ?></li>
                    <li><?php echo $this->translate('Tel'); ?> +380445685264</li>
                    <li><?php echo $this->translate('Fax'); ?> +380445685265</li>
                    <li><a href="mailto:">E-mail: info@logisticway.com</a></li>
                </ul>

                <ul id="social">
                    <li><a href="#" id="dribbble">Dribbble</a></li>
                    <li><a href="#" id="facebook">Facebook</a></li>
                    <li><a href="#" id="flickr">Flickr</a></li>
                    <li><a href="#" id="twitter">Twitter</a></li>
                    <li><a href="#" id="rss">RSS</a></li>
                </ul>
            </div>

            <div class="one-third">
                <center>
                    <h3><?php echo $this->translate('Information'); ?></h3>
                    <ul>
                       <li><a href="http://logisticway.com/"><?php echo $this->translate('Home'); ?></a></li>
                        <li><a href="/admin/add"><?php echo $this->translate('Add user'); ?></a></li>
                        <li><a href="/admin/addstatus"><?php echo $this->translate('Add status'); ?></a></li>
                        <li><a href="/markers"><?php echo $this->translate('Markers'); ?></a></li>
                        <li><a href="/rates"><?php echo $this->translate('Rates'); ?></a></li>
                        <li><a href="/requisites/updaterequisaction"><?php echo $this->translate('Requisites'); ?></a></li>
                    </ul>
                </center>
            </div>

            <div class="one-third last">
                <center><h3><?php echo $this->translate('Payment types'); ?></h3></center>
                <p><?php echo $this->translate('We can assept only limited number of payment types stated below'); ?>:</p>
                <center>
                    <img src="/img/webmoney.png" width="82" alt="webmoney" />
                    <img src="/img/bank.png" width="92" alt="bank transfer" />
                    <br />
                    <p>&nbsp; Webmoney &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <?php echo $this->translate('Bank transfer'); ?></p>
                </center>
            </div>
        </div><!-- /wrapper -->
